package org.example.order.domain;

import java.math.BigDecimal;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import org.example.contract.domain.ContractProduct;

/**
 * 订单对象 mall_order
 *
 * @author 小孟微信：xiaomengcode
 * @date 2024-04-12
 */
public class Order extends ContractProduct
{
    private static final long serialVersionUID = 1L;

    /** 订单id */
    private Long orderId;

    /** 合同ID */
    @Excel(name = "合同ID")
    private String contractId;

    /** 订单号 */
    @Excel(name = "订单号")
    private String orderNo;

    /** 供应商ID */
    @Excel(name = "供应商ID")
    private Long supplierId;

    /** 订单类型（0采购1销售） */
    @Excel(name = "订单类型", readConverterExp = "0=采购1销售")
    private Integer orderType;

    /** 订单内容 */
    @Excel(name = "订单内容")
    private String orderContent;

    /** 订单状态 */
    @Excel(name = "订单状态")
    private String orderStatus;

    /** 订单商品总数 */
    @Excel(name = "订单商品总数")
    private Integer totalNum;

    /** 订单总价 */
    @Excel(name = "订单总价")
    private BigDecimal totalPrice;

    /** 实际支付金额 */
    @Excel(name = "实际支付金额")
    private BigDecimal payPrice;


    @Excel(name = "已对账金额")
    private BigDecimal accountMoney;

    @Excel(name = "入库|出库")
    private BigDecimal useMoney;
    /** 实际支付时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "实际支付时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date payTime;

    /** 支付截止时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "支付截止时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date payEndTime;

    /** 支付交易号 */
    @Excel(name = "支付交易号")
    private String transactionId;

    /** 发货备注 */
    @Excel(name = "发货备注")
    private String deliveryRemark;

    /** 快件号 */
    @Excel(name = "快件号")
    private String expressNo;

    /** 收货方式 */
    @Excel(name = "收货方式")
    private Integer receiptMode;

    /** 收货人姓名 */
    @Excel(name = "收货人姓名")
    private String receiptName;

    /** 收货人电话 */
    @Excel(name = "收货人电话")
    private String receiptPhone;

    /** 收货时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "收货时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date receiptTime;

    /** 收货详细地址 */
    @Excel(name = "收货详细地址")
    private String receiptAddress;

    /** 买家备注 */
    @Excel(name = "买家备注")
    private String buyerRemark;

    /** 卖家备注 */
    @Excel(name = "卖家备注")
    private String sellerRemark;

    /** 是否删除 */
    private String delFlag;

    public BigDecimal getUseMoney() {
        return useMoney;
    }

    public void setUseMoney(BigDecimal useMoney) {
        this.useMoney = useMoney;
    }

    public BigDecimal getAccountMoney() {
        return accountMoney;
    }

    public void setAccountMoney(BigDecimal accountMoney) {
        this.accountMoney = accountMoney;
    }

    public void setOrderId(Long orderId)
    {
        this.orderId = orderId;
    }

    public Long getOrderId()
    {
        return orderId;
    }
    public void setContractId(String contractId)
    {
        this.contractId = contractId;
    }

    public String getContractId()
    {
        return contractId;
    }
    public void setOrderNo(String orderNo)
    {
        this.orderNo = orderNo;
    }

    public String getOrderNo()
    {
        return orderNo;
    }
    public void setSupplierId(Long supplierId)
    {
        this.supplierId = supplierId;
    }

    public Long getSupplierId()
    {
        return supplierId;
    }
    public void setOrderType(Integer orderType)
    {
        this.orderType = orderType;
    }

    public Integer getOrderType()
    {
        return orderType;
    }
    public void setOrderContent(String orderContent)
    {
        this.orderContent = orderContent;
    }

    public String getOrderContent()
    {
        return orderContent;
    }
    public void setOrderStatus(String orderStatus)
    {
        this.orderStatus = orderStatus;
    }

    public String getOrderStatus()
    {
        return orderStatus;
    }
    public void setTotalNum(Integer totalNum)
    {
        this.totalNum = totalNum;
    }

    public Integer getTotalNum()
    {
        return totalNum;
    }
    public void setTotalPrice(BigDecimal totalPrice)
    {
        this.totalPrice = totalPrice;
    }

    public BigDecimal getTotalPrice()
    {
        return totalPrice;
    }
    public void setPayPrice(BigDecimal payPrice)
    {
        this.payPrice = payPrice;
    }

    public BigDecimal getPayPrice()
    {
        return payPrice;
    }
    public void setPayTime(Date payTime)
    {
        this.payTime = payTime;
    }

    public Date getPayTime()
    {
        return payTime;
    }
    public void setPayEndTime(Date payEndTime)
    {
        this.payEndTime = payEndTime;
    }

    public Date getPayEndTime()
    {
        return payEndTime;
    }
    public void setTransactionId(String transactionId)
    {
        this.transactionId = transactionId;
    }

    public String getTransactionId()
    {
        return transactionId;
    }
    public void setDeliveryRemark(String deliveryRemark)
    {
        this.deliveryRemark = deliveryRemark;
    }

    public String getDeliveryRemark()
    {
        return deliveryRemark;
    }
    public void setExpressNo(String expressNo)
    {
        this.expressNo = expressNo;
    }

    public String getExpressNo()
    {
        return expressNo;
    }
    public void setReceiptMode(Integer receiptMode)
    {
        this.receiptMode = receiptMode;
    }

    public Integer getReceiptMode()
    {
        return receiptMode;
    }
    public void setReceiptName(String receiptName)
    {
        this.receiptName = receiptName;
    }

    public String getReceiptName()
    {
        return receiptName;
    }
    public void setReceiptPhone(String receiptPhone)
    {
        this.receiptPhone = receiptPhone;
    }

    public String getReceiptPhone()
    {
        return receiptPhone;
    }
    public void setReceiptTime(Date receiptTime)
    {
        this.receiptTime = receiptTime;
    }

    public Date getReceiptTime()
    {
        return receiptTime;
    }
    public void setReceiptAddress(String receiptAddress)
    {
        this.receiptAddress = receiptAddress;
    }

    public String getReceiptAddress()
    {
        return receiptAddress;
    }
    public void setBuyerRemark(String buyerRemark)
    {
        this.buyerRemark = buyerRemark;
    }

    public String getBuyerRemark()
    {
        return buyerRemark;
    }
    public void setSellerRemark(String sellerRemark)
    {
        this.sellerRemark = sellerRemark;
    }

    public String getSellerRemark()
    {
        return sellerRemark;
    }
    public void setDelFlag(String delFlag)
    {
        this.delFlag = delFlag;
    }

    public String getDelFlag()
    {
        return delFlag;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("orderId", getOrderId())
            .append("contractId", getContractId())
            .append("orderNo", getOrderNo())
            .append("supplierId", getSupplierId())
            .append("orderType", getOrderType())
            .append("orderContent", getOrderContent())
            .append("orderStatus", getOrderStatus())
            .append("totalNum", getTotalNum())
            .append("totalPrice", getTotalPrice())
            .append("payPrice", getPayPrice())
            .append("payTime", getPayTime())
            .append("payEndTime", getPayEndTime())
            .append("transactionId", getTransactionId())
            .append("deliveryRemark", getDeliveryRemark())
            .append("expressNo", getExpressNo())
            .append("receiptMode", getReceiptMode())
            .append("receiptName", getReceiptName())
            .append("receiptPhone", getReceiptPhone())
            .append("receiptTime", getReceiptTime())
            .append("receiptAddress", getReceiptAddress())
            .append("buyerRemark", getBuyerRemark())
            .append("sellerRemark", getSellerRemark())
            .append("delFlag", getDelFlag())
            .append("createTime", getCreateTime())
            .append("createBy", getCreateBy())
            .append("remark", getRemark())
            .toString();
    }
}
